package com.hutu.erp.catalog.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.hutu.erp.catalog.mapper.SpecificationMappingMapper;
import com.hutu.erp.catalog.domain.SpecificationMapping;
import com.hutu.erp.catalog.service.ISpecificationMappingService;

/**
 * 商品参数值Service业务层处理
 * 
 * @author ruoyi
 * @date 2021-05-24
 */
@Service
public class SpecificationMappingServiceImpl implements ISpecificationMappingService 
{
    @Autowired
    private SpecificationMappingMapper specificationMappingMapper;

    /**
     * 查询商品参数值
     * 
     * @param mappingId 商品参数值ID
     * @return 商品参数值
     */
    @Override
    public SpecificationMapping selectSpecificationMappingById(Long mappingId)
    {
        return specificationMappingMapper.selectSpecificationMappingById(mappingId);
    }

    /**
     * 查询商品参数值列表
     * 
     * @param specificationMapping 商品参数值
     * @return 商品参数值
     */
    @Override
    public List<SpecificationMapping> selectSpecificationMappingList(SpecificationMapping specificationMapping)
    {
        return specificationMappingMapper.selectSpecificationMappingList(specificationMapping);
    }

    /**
     * 新增商品参数值
     * 
     * @param specificationMapping 商品参数值
     * @return 结果
     */
    @Override
    public int insertSpecificationMapping(SpecificationMapping specificationMapping)
    {
        return specificationMappingMapper.insertSpecificationMapping(specificationMapping);
    }

    /**
     * 修改商品参数值
     * 
     * @param specificationMapping 商品参数值
     * @return 结果
     */
    @Override
    public int updateSpecificationMapping(SpecificationMapping specificationMapping)
    {
        return specificationMappingMapper.updateSpecificationMapping(specificationMapping);
    }

    /**
     * 批量删除商品参数值
     * 
     * @param mappingIds 需要删除的商品参数值ID
     * @return 结果
     */
    @Override
    public int deleteSpecificationMappingByIds(Long[] mappingIds)
    {
        return specificationMappingMapper.deleteSpecificationMappingByIds(mappingIds);
    }

    /**
     * 删除商品参数值信息
     * 
     * @param mappingId 商品参数值ID
     * @return 结果
     */
    @Override
    public int deleteSpecificationMappingById(Long mappingId)
    {
        return specificationMappingMapper.deleteSpecificationMappingById(mappingId);
    }
}
